﻿@{
    ViewBag.Title = "Index";
    Layout = null;
}
<!DOCTYPE html>
second
<html>
<head>
    <meta charset="UTF-8">
    @*<meta name="viewport" content="width=device-width" />*@
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
    @*<link href="~/Content/Style/gobal.css" rel="stylesheet" />*@
    <script src="~/Content/Script/jquery.min.js"></script>
    <title>Index</title>
    <script>
        var intervalid1, intervalid2, s = 2;
        $(document).ready(function () {
            $('#spinner').hide(); second
            intervalid1 = setInterval('showUnreadNews()', 2000);
        });
        function showUnreadNews() {
            $.ajax({
                type: "GET",
                url: "/Order/FormIsPay",
                success: function (msg) {
                    if (msg == "1") {
                        clearInterval(intervalid1);
                        $('#spinner').show();//正在加载字样显示
                        intervalid2 = setInterval('test()', 1000);
                    }
                }
            });
        }
        function test() {
            if (s == 0) {
                window.location.href = "/Order/OrderList";
                clearInterval(intervalid2);
            }
            document.getElementById("second").innerHTML = s;
            s--;
        }
    </script>
    <style>
        #spinner {
            position: fixed;
            left: 5%;
            display: block;
            color: red;
            font-weight: 900;
            background-color: white;
            /*background-color: rgba(80, 80, 90, 0.22);*/
            border-radius: 15px;
            top: 100px;
            width: 90%;
            /*height: 100px;*/
            line-height: 50px;
            text-align: center;
        }
    </style>
</head>
<body>
    <div id="spinner">
        <p>付款成功，2秒后返回订单列表页</p>
        <h1><span id="second">2</span>...</h1>
    </div>
    <div style="text-align:center">
        @*<div style="margin:20px 0;color:red;font-size:20px"><span>支付金额：</span><span>888元</span></div>*@

        <div>
            <img src="/WeChatPay/Image" alt="支付二维码" style="width:80%"/>
            <p>长按二维码图片进行支付</p>
        </div>

        <div>
            @*<a href="/PersonalCenter/orderlist">支付完成</a>*@
        </div>
    </div>
</body>
</html>
